import { Image } from "./asset";

export interface Ifood {
  id: number;
  name: string;
  img: string;
  price: number;
  type: string;
  material: string;
  content: string;
  count: number;
  buyCount: number;
  btn?: boolean;
  sales: number;
  createTime: string;
  updateTime: string;
  version: number;
  order: number;
  taste?: number;
}

interface SKU {
  sku_id: string;
  json: SkuJson;
}

interface SkuJson {
  tree: Array<any>,
  list: Array<any>,
}

export interface FoodItem {
  description: string;
  goods_id: number;
  img_id: {
    full_url: string;
    id: number;
    url: string;
  };
  market_price: string;
  price: string;
  sku: Array<SKU>;
  title: string;
  [key: string]: any;
}

export interface FoodsCategory {
  category_id: number;
  short_name: string;
  pid: number;
  level: number;
  is_visible: boolean;
  sort?: string;
  category_pic: string;
  ucid: number;
  created_at: string;
  updated_at: string;
  img: Image;
  path?: string;
  title?: string;
  [key: string]: any;
}
